STEP 6: Percent problems can be completed in two steps. We'll start by finding the value of the discount!

In Python, you can multiply two values using * and divide two values using /.

  • In LOGIC, go to . Drag out Float Variable.
  • Change the variable name from my_var to discount.
  • Change the value from 2.34 to price * percent/100.

To navigate the page using the TAB key, first press ESC to exit the code editor.

# THIS ACTIVITY IS IN PREVIEW ONLY MODE
  • Run Code
  • Submit Work
  • Next Activity
  • Show Console
  • Reset Code Editor
  • Codesters How To (opens in a new tab)